using IM.Easy.Entity.Log;
using IM.Easy.Infrastructure.Query;
using System.ComponentModel.DataAnnotations;


namespace IM.Easy.LogServices.Dtos
{
    /// <summary>
    /// 登录，注销操作日志表查询实体
    /// </summary>
    public class SessionLogQueryDto : QueryBase
    {
         /// <summary>
         /// 操作时间开始
         /// </summary>
         public DateTime? BeginActionTime { get; set; }
         /// <summary>
         /// 操作时间结束
         /// </summary>
         public DateTime? EndActionTime { get; set; }
        /// <summary>
        /// 用户名
        /// </summary>
        public string UserName { get; set; }
    }

    /// <summary>
    /// 登录，注销操作日志表dto
    /// </summary>
    public class SessionLogDto
    {
        /// <summary>
        /// 日志唯一ID
        /// </summary>
        public string Id { get; set; }
        /// <summary>
        /// 用户ID
        /// </summary>
        public long UserId { get; set; }
        /// <summary>
        /// 操作类型：登录或注销
        /// </summary>
        public int ActionType { get; set; }
        /// <summary>
        /// 操作时间
        /// </summary>
        public DateTime ActionTime { get; set; }
        /// <summary>
        /// 用户名
        /// </summary>
        public string UserName { get; set; }
        /// <summary>
        /// 登录终端
        /// </summary>
        public TerminalType Terminal { get; set; }
        /// <summary>
        /// 操作描述
        /// </summary>
        public string Description { get; set; }
        /// <summary>
        /// 追踪ID
        /// </summary>
        public string TraceIdentifier { get; set; }
    }
}
